#ifndef _GORBATRAS_FBXANIMATIONCHANNEL
#define _GORBATRAS_FBXANIMATIONCHANNEL

#include "Gorbatras_Library.h"

namespace GC
{
	class FbxAnimationCurve;	

	class FbxAnimationChannel
	{
		public:
					

			enum ChannelType
			{
				Translation = 0,
				Rotation = 1,
				Scale = 2
			};			

			FbxAnimationChannel( FbxAnimLayer* a_layer, FbxNode* a_node ,const ChannelType a_type, const double a_deltaFrameTime );	
			

			const bool IsValid() const;			
			//Returns the max length of the channel, as in what last frame number for the animation is
			const int GetAnimationLength() const;
			
			const bool HasValueAtFrame( const int a_frameNumber ) const;
			//Returns a FbxVector4 with the values at that frame			
			void GetValueAtFrame( const int a_frame, FbxVector4& a_dest ) const;

		private:
			typedef std::shared_ptr<FbxAnimationCurve> FbxAnimationCurvePtr;

			FbxAnimationCurvePtr m_x;
			FbxAnimationCurvePtr m_y;
			FbxAnimationCurvePtr m_z;

			FbxAnimCurve* TryToGetCurve(FbxAnimLayer* a_layer, FbxNode* a_node, const ChannelType a_type, const char* a_dimension);
	};
}

#endif